import java.util.Scanner;
public class CombinNum {
    public static void main(String[] args) {
        System.out.print("请输入整数m、n:");
        Scanner reader = new Scanner(System.in);
        int m = reader.nextInt();
        int n = reader.nextInt();
        System.out.println(comm(m,n));
    }
    public static int comm(int m,int n) {
        if (m==n||n==0)
            return 1;
        else if (n==1)
            return m;
        else
            return comm(m-1,n-1)+comm(m-1,n);
    }

}
